Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ignore unknown test app messages #2103

Merged
merged 1 commit into from
Dec 5, 2023
Merged

Ignore unknown test app messages #2103

merged 1 commit into from
Dec 5, 2023

Conversation

nmattia
Copy link
Collaborator

@nmattia nmattia commented Dec 4, 2023

This updates the test app to ignore unknown window events. Some extensions, like metamask, send seemingly arbitrary messages to the window which confuses the test app.

With these changes we try to figure out if a message was intended for us by

  1. Ensuring a request was started
  2. Checking the jsonrpc response ID

🟡 Some screens were changed

@nmattia nmattia marked this pull request as draft December 5, 2023 09:07
@nmattia
Copy link
Collaborator Author

nmattia commented Dec 5, 2023

Bit of an issue here, needs debugging FIXED

@nmattia nmattia force-pushed the nm-ignore-unknown-resps branch 2 times, most recently from 56ae897 to 641d556 Compare December 5, 2023 09:26
This updates the test app to ignore unknown window events. Some
extensions, like metamask, send seemingly arbitrary messages to the
window which confuses the test app.

With these changes we try to figure out if a message was intended for us
by

1. Ensuring a request was started
2. Checking the jsonrpc response ID
@nmattia nmattia force-pushed the nm-ignore-unknown-resps branch from 641d556 to f3dd093 Compare December 5, 2023 09:36
@nmattia nmattia marked this pull request as ready for review December 5, 2023 09:40
Copy link
Contributor

@frederikrothenberger frederikrothenberger left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, works with Metamask active in FF now. Thanks!

@nmattia nmattia added this pull request to the merge queue Dec 5, 2023
Merged via the queue into main with commit 2cee1c0 Dec 5, 2023
53 checks passed
@nmattia nmattia deleted the nm-ignore-unknown-resps branch December 5, 2023 10:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants